#尝试锻造

#CONSUME
data modify storage vs:system temp.forge.consume.UUID set from entity @p[tag=player] UUID
data modify storage vs:system temp.forge.consume.count set from entity @n[tag=smithingTable.itemSlot,distance=..5,type=item_display] item.components."minecraft:custom_data".forge.price
function vs:system/game_ctrol/smithing_table/forge/consume_voidogen with storage vs:system temp.forge.consume

#Type: loot_table
data modify storage vs:system temp.forge.type set from entity @n[tag=smithingTable.itemSlot,distance=..3,type=item_display] item.components."minecraft:custom_data".forge.product.type
execute if data storage vs:system temp.forge{type:"loot_table"} run data modify storage vs:system temp.forge.path set from entity @n[tag=smithingTable.itemSlot,distance=..3,type=item_display] item.components."minecraft:custom_data".forge.product.path

#output
function vs:system/game_ctrol/smithing_table/forge/output_product/output_forge_product with storage vs:system temp.forge

data remove storage vs:system temp.forge